package com.atguigu.dao.impl;

import com.atguigu.dao.OrderItemDao;
import com.atguigu.pojo.OrderItem;

public class OrderItemDaoImpl extends BaseDaoimpl<OrderItem> implements OrderItemDao {

	@Override
	public void saveOrderItem(OrderItem orderItem) {
		String sql = "insert into t_order_item(`name`,`count`,`price`,`totalPrice`, `order_id`)"
				+ " values(?,?,?,?,?)";
		update(sql, orderItem.getName(),orderItem.getCount(),
				orderItem.getPrice(),orderItem.getTotalPrice(),orderItem.getOrderId());
	}

}
